package com.projectplace.api.objectResponses;

/*
 * Copyright (c) 2011 Projectplace International AB
 * Permission is hereby granted, free of charge, to any person 
 * obtaining a copy of this software and associated documentation 
 * files (the "Software"), to deal in the Software without restriction, 
 * including without limitation the rights to use, copy, modify, merge, 
 * publish, distribute, sublicense, and/or sell copies of the Software, 
 * and to permit persons to whom the Software is furnished to do so, 
 * subject to the following conditions:The above copyright notice and this 
 * permission notice shall be included in all copies or substantial portions of the Software.
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
 * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 
 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 
 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 */

import org.json.JSONObject;

public class ppApiUser implements PPApiU{
	
	private JSONObject user;
	private boolean favorite = false;
	
	public ppApiUser(JSONObject user){
		this.user = user;
	}
	
	public boolean isFavorite(){
		return favorite;
	}
	
	public void setFavorite(boolean fav){
		favorite = fav;
	}
	
	public String getID(){
		return user.optString("id");
	}
	public String getAddress1(){
		return user.optString("address1");
	}
	public String getAddress2(){
		return user.optString("address2");
	}
	public String getCity(){
		return user.optString("city");
	}
	public String getCountry_Code(){
		return user.optString("country_code");
	}
	public String getDescription(){
		return user.optString("description");
	}
	public String getEmail(){
		return user.optString("email");
	}
	public String getFirst_Name(){
		return user.optString("first_name");
	}
	public String getHome_Phone(){
		return user.optString("home_phone");
	}
	public String getHomepage(){
		return user.optString("homepage");
	}
	public String getLast_Name(){
		return user.optString("last_name");
	}
	public String getMobile_Phone(){
		return user.optString("mobile_phone");
	}
	public String getOrganisation_Homepage(){
		return user.optString("organisation_homepage");
	}
	public String getOrganisation_Name(){
		return user.optString("organisation_name");
	}
	public String getProvince(){
		return user.optString("province");
	}
	public String getSort_Name(){
		return user.optString("sort_name");
	}
	public String getTitle(){
		return user.optString("title");
	}
	public String getWork_Phone(){
		return user.optString("work_phone");
	}
	public String getZip_Code(){
		return user.optString("zip_code");
	}
	
}
